package day2018_lab02.test06;

public class Ladder {

    //Ladder类具有类型double的上底、下底、高、面积属性，具有返回面积的功能。
    double shang;
    double xia;
    double gao;
    double mianji;

    public void setShang(double shang) {
        this.shang = shang;
    }

    public double getShang() {
        return shang;
    }

    public void setGao(double gao) {
        this.gao = gao;
    }

    public double getGao() {
        return gao;
    }

    public void setXia(double xia) {
        this.xia = xia;
    }

    public double getXia() {
        return xia;
    }



    public double getMianji() {
        mianji=(shang+xia)*gao/2;
        return mianji;
    }

}
